<%@ taglib uri="/WEB-INF/myfaces_html.tld" 	prefix="h" %>
<%@ taglib uri="/WEB-INF/myfaces_core.tld" 	prefix="f" %>
<%@ taglib uri="/WEB-INF/tomahawk.tld"     	prefix="t" %>
<%@ page import="it.azienda.framework.utilita.Utilita" %>
<%@ page import="java.util.*" %>    
<%@ page import="javax.faces.context.FacesContext" %>
<%
    java.util.ResourceBundle bundle = java.util.ResourceBundle.getBundle(FacesContext.getCurrentInstance().getApplication().getMessageBundle(), FacesContext.getCurrentInstance().getApplication().getDefaultLocale());
    String versioneSw=bundle.getString("managerwork_titolo");
%> 
            
    <f:view>   
        <html lang="it">
            <head>
                <title><%=versioneSw%> - Ricerca Vettori</title>   
                <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" >
                <link rel="stylesheet" href="../managerwork.css" type="text/css">
            </head>        
            <body>                
                <h:form id="uno">
                    <table class="lookUp">
                        <tr>     
                            <td class="lookUptd" colspan="5" align="center"><strong><t:outputLabel for="ricerca" value="Modulo di Ricerca Vettori" /></strong></td>                        
                        </tr>     

                        <tr>     
                            <td class="lookUptd"><strong><t:outputLabel for="prop1" value="Cognome:" /></strong></td>            
                            <td><t:inputText id="prop1" value="#{beanFind.prop1}" size="30" maxlength="30" styleClass="viewEtichetta" onchange="this.value=this.value.toUpperCase()" /></td>
                        </tr>     
                        
                        <tr>     
                            <td class="lookUptd"><strong><t:outputLabel for="prop2" value="Nome:" /></strong></td>            
                            <td><t:inputText id="prop2" value="#{beanFind.prop2}" size="30" maxlength="30" styleClass="viewEtichetta" onchange="this.value=this.value.toUpperCase()" /></td>
                        </tr> 
                        
                        <tr>     
                            <td class="lookUptd"><strong><t:outputLabel for="prop3" value="Comune:" /></strong></td>            
                            <td><t:inputText id="prop3" value="#{beanFind.prop3}" size="30" maxlength="30" styleClass="viewEtichetta" onchange="this.value=this.value.toUpperCase()" /></td>
                        </tr> 
                        
                        <tr>     
                            <td class="lookUptd"><strong><t:outputLabel for="prop4" value="Provincia:" /></strong></td>
                            <td><t:inputText id="prop4" value="#{beanFind.prop4}" size="30" maxlength="30"  styleClass="viewEtichetta" onchange="this.value=this.value.toUpperCase()" /></td>                
                        </tr>      
                        
                        <tr>     
                            <td class="lookUptd"><strong><t:outputLabel for="prop5" value="CAP:" /></strong></td>
                            <td><t:inputText id="prop5" value="#{beanFind.prop5}" size="30" maxlength="30"  styleClass="viewEtichetta" /></td>                
                        </tr>      
                        
                        <tr>     
                            <td class="lookUptd"><strong><t:outputLabel for="prop6" value="Professione:" /></strong></td>            
                            <td><t:inputText id="prop6" value="#{beanFind.prop6}" size="30" maxlength="30" styleClass="viewEtichetta" onchange="this.value=this.value.toUpperCase()" /></td>
                        </tr> 
                        <tr>   
                            <td class="lookUptd"><strong><t:outputLabel for="ordinamento" value="Ordinamento:" /></strong></td>                                               
                            <td>
                                <h:selectOneMenu id="ordinamento" value="#{beanFind.ordinamento}" >
                                    <f:selectItems value="#{beanRubrica.ordinamento}" />
                                </h:selectOneMenu>           
                            </td>   
                        </tr>  

                        <t:inputHidden id="tabella" value="rubrica" />                    
                        <t:inputHidden id="bean" value="BeanRubrica" />                    
                        <t:inputHidden id="proprieta" value="cognome,nome,tableComuni-BeanComune-descrizione-comune_id,padreProvince-figlioComuni-descrizione-provincia_id-BeanComune-comune_id,tableComuni-BeanComune-cap-comune_id,professione"/>          
               
                        <tr>
                            <td>
                                <t:commandButton value="Invia" actionListener="#{dettaglioRubrica.ricercaOggettiFind}" onclick="window.setTimeout('esegui()', 100)" immediate="true">                        
                                </t:commandButton>                                                                  
                            </td>                              
                            <td>
                                <t:commandButton value="Chiudi" action="#{dettaglioRubrica.resettaLookup}" onclick="javascript:window.close()" immediate="true" >                         
                                </t:commandButton>                       
                            </td>                                                 
                        </tr>                
                    </table>
                </h:form>   
                <h:form id="erroriDataBase" rendered="false">
                    <td align="left" class="messaggiErrore" height="2px">           
                        <h:messages  style="color: red" showDetail="true" showSummary="false"/>
                    </td>
                </h:form>            
                <script>
                    function esegui(){
                    window.opener.document.getElementById("formLookup:lista").click()
                    window.close()
                    }
                </script>
            </body>
        </html>
    </f:view>
